using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class UpgradeCidiumLooting:Upgrade {

	protected override void SubscribeEvents() {
		base.SubscribeEvents();
		Mob.Death+=Mob_Death;
	}
	public override void UnsubscribeEvents() {
		base.UnsubscribeEvents();
		Mob.Death-=Mob_Death;
	}

	private void Mob_Death(object _sender,DeathEventArgs e) {
		if(e.killerWeapon!=weaponWeapon) return;
		Mob sender = _sender as Mob;
		EnergyPickup.Create(sender.position,1);
	}
}
